Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve auto login issue when refreshToken is missing #98

Merged
merged 1 commit into from
Oct 5, 2024
Merged

Resolve auto login issue when refreshToken is missing #98

merged 1 commit into from
Oct 5, 2024

Conversation

jimwbaldwin
Copy link
Contributor

Hey Victor,

Firstly, thanks for providing this tool.

I was having this issue mentioned in issue #97.

I read the create-token documentation and if the grant-type is refresh_token then refreshToken is required. So I changed the code so that it doesn't attempt to create the token if refreshToken is not found in the cached login.

This avoids the KeyError exception.

I have tested this locally by running make test as well as changing the order of when the refreshToken is tried to before other methods and testing. This worked also.

image

Please let me know if you have any feedback. I didn't bump the release number as I can see you do that in another commit.

I also tried to match your code style as much as possible.

Thanks.

Resolve auto login issue when refreshToken is missing
@victorskl
Copy link
Owner

Thanks Jim. I will look into this in tick, soon.

@victorskl victorskl self-requested a review October 3, 2024 23:36
@victorskl victorskl linked an issue Oct 5, 2024 that may be closed by this pull request
@victorskl victorskl added this to the 1.2.1 milestone Oct 5, 2024
Copy link
Owner

@victorskl victorskl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fix work. I will take in changes and make patch release.
Thanks Jim.

@victorskl victorskl added the fix label Oct 5, 2024
@victorskl victorskl merged commit 5fcd464 into victorskl:main Oct 5, 2024
4 of 9 checks passed
@jimwbaldwin
Copy link
Contributor Author

Awesome. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

KeyError: 'refreshToken' after updating to 1.2.0
2 participants